/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package com.pa165.languageschoolservice.DTO;

import com.pa165.languageschoolpersistence.entities.Difficulty;
import com.pa165.languageschoolpersistence.entities.LanguageSpoken;
import java.io.Serializable;
import javax.xml.bind.annotation.XmlRootElement;


/**
 *
 * @author Aleksei Penzentcev
 */
@XmlRootElement
public class CourseDTO implements Serializable {

    private static final long serialVersionUID = 1L;
    private Long id;

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }
   
    private String name;

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }
    
    private LanguageSpoken language;

    public LanguageSpoken getLanguage() {
        return language;
    }

    public void setLanguage(LanguageSpoken language) {
        this.language = language;
    }
    private Difficulty difficulty;

    public Difficulty getDifficulty() {
        return difficulty;
    }

    public void setDifficulty(Difficulty difficulty) {
        this.difficulty = difficulty;
    }

    @Override
    public int hashCode() {
        int hash = 0;
        hash += (id != null ? id.hashCode() : 0);
        return hash;
    }

    @Override
    public boolean equals(Object obj) {
        if (obj == null) {
            return false;
        }
        if (getClass() != obj.getClass()) {
            return false;
        }
        final CourseDTO other = (CourseDTO) obj;
        if (this.id != other.id && (this.id == null || !this.id.equals(other.id))) {
            return false;
        }
        return true;
    }

    @Override
    public String toString() {
        return "CourseDTO:{id=" + id + ", name=" + name + ", language=" + language + ", difficulty =" + difficulty + "}";
    }
}
